package com.jic.member.mapper;
import com.jic.common.base.orm.BaseMapper;
import com.jic.common.base.orm.Pagination;
import com.jic.member.entity.TripEntity;
import com.jic.member.request.TripEntityQueryRequest;
import com.jic.member.response.TripEntityResponse;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface TripEntityMapper extends BaseMapper<TripEntity>{

    long updateStatus(TripEntity tripEntity);

    /**
     * 管理页面分页查询用户旅程
     * @param tripEntityQueryRequest
     * @param pagination
     * @return
     */
    List<TripEntityResponse> queryPage(@Param("tripEntity") TripEntityQueryRequest tripEntityQueryRequest, @Param("page") Pagination pagination);

    /**
     * 管理页面分页查询用户旅程
     * @param tripEntity
     * @return
     */
    int queryPageCount(@Param("tripEntity") TripEntityQueryRequest tripEntity);
}